package com.szgr.baoyin.activity;

import android.content.Intent;
import android.os.Bundle;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.webkit.WebSettings;
import android.webkit.WebView;

import com.szgr.baoyin.R;
import com.szgr.baoyin.utils.Constant;

/**
 * 融资流程
 */
public class FinanceProcessActivity extends BaseActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        setContentView(R.layout.activity_finance_process);
        super.onCreate(savedInstanceState);
    }

    @Override
    public void initActionBar() {
        actionBarTitle.setText("融资流程");
    }

    @Override
    public void initView() {
        WebView webView = (WebView) findViewById(R.id.finance_process_web_view);
        WebSettings settings = webView.getSettings();
        settings.setJavaScriptEnabled(true);
        Intent intent = getIntent();
        if(intent != null){
            String from = intent.getStringExtra("from");
            if("first".equals(from)){
                webView.loadUrl(Constant.URL_FINANCE_01);
            }else if("second".equals(from)){
                webView.loadUrl(Constant.URL_FINANCE_02);
            }
        }
    }

    @Override
    public void onClick(View v) {
        switch (v.getId()){
            case R.id.action_bar_left:
                finish();
                break;
        }
    }
}
